﻿<Window
	xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
	xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:dc="clr-namespace:WPFNotifyIcon" 
	x:Class="RemoteDesktops.MainWindow"
	x:Name="Window"
	Title="Remote Desktop Organizer"
	Width="640" Height="480" Icon="/RemoteDesktops;component/Icons/app.ico" ShowInTaskbar="True">

    <Window.Resources>
        <ContextMenu x:Key="DCM" x:Name="DesktopContextMenu">
            <MenuItem Header="Start" Click="LaunchDesktop_Click"/>
            <Separator></Separator>
            <MenuItem Header="Delete" Click="DeleteDesktop_Click"/>
        </ContextMenu>
        
        <ContextMenu x:Key="MWCM" x:Name="CreateDesktopContextMenu">
            <MenuItem Header="New Desktop" Click="CreateDesktop_Click">
                <MenuItem.Icon>
                    <Image Source="Icons\computer2.ico" Height="16" Width="16"/>
                </MenuItem.Icon>
            </MenuItem>
        </ContextMenu>        
    </Window.Resources>
    
    
    <Grid x:Name="LayoutRoot">
        <dc:NotifyIcon
			x:Name="notifyIcon"
			Text="{Binding ElementName=tipText,Path=Text}"
			Icon="Icons/computer3.ico"
			BalloonTipText="{Binding Text, ElementName=balloonTipText}"
			BalloonTipTitle="{Binding Text, ElementName=balloonTipTitle}"
			BalloonTipIcon="Info"
            MouseDoubleClick="notifyIcon_MouseDoubleClick">
            <dc:NotifyIcon.ContextMenu>
                <ContextMenu>
                    <MenuItem Header="Open" Click="OnOpenClick">
                        <MenuItem.Icon>
                            <Image Source="Icons/computer3.ico" Height="16" Width="16"></Image>
                        </MenuItem.Icon>
                    </MenuItem>
                    <Separator></Separator>
                    <Separator></Separator>
                    <MenuItem Header="Exit" Click="OnExitClick">
                        <MenuItem.Icon>
                            <Image Source="Icons/exit.ico" Height="16" Width="16"></Image>
                        </MenuItem.Icon>
                    </MenuItem>
                </ContextMenu>
            </dc:NotifyIcon.ContextMenu>
        </dc:NotifyIcon>
        
        <Rectangle Height="41" Stroke="#FFFFFFFF" VerticalAlignment="Bottom" Margin="0">
			<Rectangle.Fill>
				<LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
					<GradientStop Color="#FFD6D6D6" Offset="1"/>
					<GradientStop Color="White" Offset="0.252"/>
				</LinearGradientBrush>
			</Rectangle.Fill>
		</Rectangle>
        <Menu Height="33" VerticalAlignment="Top" x:Name="MainMenu">
			<!--File -->
            <MenuItem Header="File" x:Name="FileMenu">
				<MenuItem Header="New Desktop" Click="NewDesktop_Click" x:Name="NewDesktopAddMenu">					
                    <MenuItem.Icon>
                        <Image Source="Icons\computer2.ico" Height="18" Width="18"/>
                    </MenuItem.Icon>
				</MenuItem>
                <Separator Height="1"></Separator>
                <MenuItem Header="Exit" Click="OnExitClick" x:Name="Exit">
                    <MenuItem.Icon>
                        <Image Source="Icons\exit.ico" Height="18" Width="18"/>
                    </MenuItem.Icon>
                </MenuItem>

            </MenuItem>
            <!-- Desktops -->
            <MenuItem Header="Desktops" x:Name="DesktopMenu">
                <MenuItem Header="No Desktops" x:Name="Default">
                </MenuItem>
            </MenuItem>
            <!-- Desktops -->
            <MenuItem Header="Help" x:Name="Help">
                <MenuItem Header="About" Click="AboutMenuItem_Click">
                </MenuItem>
            </MenuItem>
            <Menu.Background>
				<LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
					<GradientStop Color="#FFCCCCCC" Offset="0"/>
					<GradientStop Color="White" Offset="1"/>
				</LinearGradientBrush>
			</Menu.Background>            
		</Menu>
        
        
        <WrapPanel Margin="5,20,5,0" HorizontalAlignment="Left" VerticalAlignment="Top" x:Name="IconWrapPanel">
            <!--<StackPanel Margin="5,20,5,0" MouseEnter="StackPanel_MouseEnter" Width="80" Height="50">                
                <Image Source="Icons/computer1.ico" Height="32" Width="32"></Image>
                <TextBlock Text="Computer Name"></TextBlock>
            </StackPanel>-->
        </WrapPanel>
    </Grid>
</Window>